import request from '@/utils/request'

// 查询地震危险性评估列表
export function listEarthquake(id) {
  return request({
    url: '/fxfzaqbz/data/getEarthEntity?id='+id,
    method: 'get',
  })
}

// 查询地震危险性评估详细
export function getEarthquake(id) {
  return request({
    url: '/fxfzaqbz/data/getRiskAssessmentById?id=' + id,
    method: 'get'
  })
}

// 上传地震危险性评估
export function uploadEarthquake(data) {
  return request({
    url: '/fxfzaqbz/data/saveRiskAssessment',
    method: 'post',
    data: data
  })
}

// 上传地震危险性评估图片
export function uploadEarthquakePic(data) {
    return request({
      url: '/attachment/uploadFile',
      method: 'post',
      data: data
    })
  }

// 修改地震危险性评估
export function updateEarthquake(data) {
  return request({
    url: '/fxfzaqbz/data/updateRiskAssessment',
    method: 'post',
    data: data
  })
}

// 删除地震危险性评估
export function delEarthquake(id) {
  return request({
    url: '/fxfzaqbz/data/deleteRiskAssessment?id=' + id,
    method: 'post'
  })
}
